package com.example.demo.entity;

import lombok.Data;
import java.time.LocalDateTime;

/**
 * 对应数据库 students 表
 */
@Data
public class Student {
    private String studentId;        // 学生学号 (VARCHAR(20), 主键)
    private String studentName;      // 学生姓名 (VARCHAR(50))
    private String password;         // 账号密码 (VARCHAR(255), 实际应用中需加密)
    private String className;        // 班级名称 (VARCHAR(50))
    private Integer enrollmentYear;   // 入学年份 (INT)
    private LocalDateTime createdAt;  // 创建时间

    public String getStudentId() {
        return studentId;
    }

    public void setStudentId(String studentId) {
        this.studentId = studentId;
    }

    public String getStudentName() {
        return studentName;
    }

    public void setStudentName(String studentName) {
        this.studentName = studentName;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public String getClassName() {
        return className;
    }

    public void setClassName(String className) {
        this.className = className;
    }

    public Integer getEnrollmentYear() {
        return enrollmentYear;
    }

    public void setEnrollmentYear(Integer enrollmentYear) {
        this.enrollmentYear = enrollmentYear;
    }

    public LocalDateTime getCreatedAt() {
        return createdAt;
    }

    public void setCreatedAt(LocalDateTime createdAt) {
        this.createdAt = createdAt;
    }

    public LocalDateTime getUpdatedAt() {
        return updatedAt;
    }

    public void setUpdatedAt(LocalDateTime updatedAt) {
        this.updatedAt = updatedAt;
    }

    private LocalDateTime updatedAt;  // 更新时间
}